<%@ page import="com.psl.model.userlogin" %>
<%@ page import="java.text.SimpleDateFormat" %>
<%@ page import="java.util.Date" %>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="s" uri="/struts-tags" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<%
    userlogin userinfo = (userlogin) session.getAttribute("user");
    if (userinfo == null) {
        response.sendRedirect("/login.do");
    }
%>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <link href="/assets/css/frame.css" rel="stylesheet" type="text/css">
    <script type="text/javascript" src="/assets/js/jquery.js"></script>
    <script type="text/javascript" src="/assets/js/changeFrame.js"></script>
    <script type="text/javascript">
        $(document).ready(
            function () {
                menu("menu", "cur", "cur", "slide");
                var heightVal = (document.body.clientHeight - 53) + "px";
                $('#menuWrap').css('height', heightVal);
                window.onresize = function () {
                    var heightVal = (document.body.clientHeight - 53) + "px";
                    $('#menuWrap').css('height', heightVal);
                }
            }
        );
    </script>
    <style type="text/css">
        html, body {
            scrollbar-3d-light-color: #FFF;
            scrollbar-arrow-color: #fff;
            scrollbar-base-color: #fff;
            scrollbar-dark-shadow-color: #fff;
            scrollbar-face-color: #6D5589;
            scrollbar-highlight-color: #FFF;
            scrollbar-shadow-color: #FFF;
        }
    </style>
</head>
<script type="text/javascript">
    function leftListLoadFinish() {
        window.parent.headerFrame.document.location.href = "/topbar.do";
    }
</script>
<body class="menuFrame" onload="leftListLoadFinish()">
<div class="wrap" id="wrap">
    <div id="date">
        <p>
            <%
                SimpleDateFormat df2 = new SimpleDateFormat("yyyy年MM月dd日  E");
                Date now2 = new Date();
            %><%=df2.format(now2)%>
            <br><span>导航菜单</span></p>
    </div>
    <div id="slideMenu">
        <div class="menuWrap" id="menuWrap">
            <ul id="menu">
                <c:forEach items="${group}" var="g">
                    <li id="li">
                        <script type="text/javascript">var moduleStatus155 = true;</script>
                        <a onClick="showInfo(155)" href="/accessmodule.do?groupId=<c:out value="${g.key}"/>"
                           target="main"><span><c:out value="${g.value}"/> </span></a>
                        <ul>
                            <c:forEach items="${module}" var="m">
                                <c:choose>
                                    <c:when test="${m.groupId==g.key}">
                                        <c:if test="${m.moduleId!=0}">
                                            <li>
                                                <a href="/accessmodule.do?groupId=${m.groupId}&moduleId=${m.moduleId}"
                                                   target="main"><span>${m.moduleName}</span></a></li>
                                        </c:if>
                                    </c:when>
                                </c:choose>
                            </c:forEach>
                        </ul>
                    </li>
                </c:forEach>
            </ul>
        </div>
    </div>
</div>
<div class="sidebar">
    <s:a action="#" title="点击收缩">sidebar</s:a>
</div>
</body>
<script type="text/javascript">
    function showInfo(moduleid) {
    }
</script>
</html>